Skip to content

Fix Discover Events nudge when no events exist#631

Closed
bokelley wants to merge 1 commit intomainfrom
bokelley/fix-empty-events-nudge
Closed

Fix Discover Events nudge when no events exist#631
bokelley wants to merge 1 commit intomainfrom
bokelley/fix-empty-events-nudge

Conversation

@bokelley
Copy link
Copy Markdown
Contributor

@bokelley bokelley commented Jan 5, 2026

Summary

  • Skip "Discover Events" nudge when no upcoming events exist
  • Skip nudge when user is already registered for all upcoming events

Problem

The "Discover Events" nudge was being recommended to users even when:

  1. There are no upcoming events in the database at all
  2. The user is already registered for all available events

This led to confusing outreach like suggesting Christina discover events when there are none to discover.

Solution

Added filterDynamicEligibility() to the outbound planner that checks:

  1. If there are any upcoming events at all (via eventsDb.getUpcomingEvents())
  2. If the user is registered for all upcoming events (via eventsDb.getUserRegistrations())

If either condition is true, the "Discover Events" goal is filtered out before goal selection.

Test plan

  • Verify no type errors (npm run typecheck)
  • Verify all tests pass (npm test)
  • Manual test: User with no upcoming events should not see "Discover Events" nudge
  • Manual test: User registered for all events should not see "Discover Events" nudge

🤖 Generated with Claude Code

Skip the "Discover Events" nudge when:
- There are no upcoming events in the database
- User is already registered for all upcoming events

This prevents confusing nudges like suggesting users discover events
when there are none to discover.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant